package com.infovane.service.impl;

import java.util.List;

import com.infovane.dao.BaseDao;
import com.infovane.service.ArticleFileService;

public class ArticleFileServiceImpl implements ArticleFileService{
	
	private BaseDao baseDao;
	
	
	public BaseDao getBaseDao() {
		return baseDao;
	}


	public void setBaseDao(BaseDao baseDao) {
		this.baseDao = baseDao;
	}


	/**
	 * 添加附近对象
	 * @param Object
	 * @return boolean
	 * */
	public boolean add(Object object) {
		return this.baseDao.save(object);
	}

	/**
	 * 根据自定义索引查找符合条件的对象
	 * @param index
	 * @return List
	 * */
	public List get(String index) {
		String hql="from TArticleFile as f where f.articleFileIndex='"+index+"'";
		return this.baseDao.load(hql);
	}

}
